import { Component, OnInit } from '@angular/core';
import { LessonCode } from '../app-lesson-code';
@Component({
  selector: 'app-lesson2',
  templateUrl: './lesson2.component.html',
  styleUrls: ['./lesson2.component.scss']
})
export class Lesson2Component implements OnInit {
  code = LessonCode.lesson2code;
  currentCustomer = '{{...}}';
  itemImageUrl = 'https://game.udcode.com/static/game/upload/pingtu/girl1.jpg';
  type = 'boy';
  classes = {
    'text-warning': 'true',
    'text-center': 'true'
  };
  styles = {
    color: '#ffc107',
    textAlign: 'center'
  };
  name = '月老';
  title = '<h3 class="text-info">这里是标题</h3>';
  isBigSize = false;
  show = true;
  week =  new Date().getDay();
  wondersgroup = [
    { name: '区域卫生事业部', presonNum: 1000},
    { name: '公共卫生事业部', presonNum: 2000}
  ];
  presons = [
    {
      name: '小明',
      types: {
        sex: 0,
        age: 18,
        height: 180
      }
    },
    {
      name: '小红'
    }
  ];


  loginJson = {
    user: '',
    password: '',
    isRememberPwd: ''
  };
  loginMessage = '';
  selectItems = {
    bj: '北京',
    tj: '天津'
  };
  constructor() { }

  ngOnInit() {
  }

  getVal(): number { return 1; }

  onSave() {
    alert('我执行了onSave方法');
  }


  login($event) {
    this.loginMessage = $event;
  }
}
